package com.spider.demo5_synchronized_method;

//取钱线程类
public class DrawThread extends Thread {
    private Account account;

    public DrawThread(String name, Account acc) {
        super( name);
        this.account = acc;
    }

    @Override
    public void run() {
        //模拟取钱
        account.drawMoney(100000);
    }
}
